import 'package:flutter/services.dart';

class ScreenControlUtils {

  // 设置横屏
  static Future<void> setting() async {
    // 强制横屏
    await SystemChrome.setPreferredOrientations([DeviceOrientation.landscapeLeft]);
  }

  // 设置竖屏
  static Future<void> settingPortrait() async {
    // 强制竖屏
    await SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp]);
  }

}
